﻿using Models;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using DAL;

namespace BLL
{
    public class UserManager
    {
        /// <summary>
        /// 用户添加
        /// </summary>
        /// <param name="user"></param>
        /// <returns></returns>
        public static bool GetUserAdd(User user)
        {
            return UserService.UserAdd(user);
        }
        /// <summary>
        /// 用户查询
        /// </summary>
        /// <returns></returns>
        public static List<User> GetUserselect()
        {
            return UserService.Userselect();
        }
        /// <summary>
        /// 用户删除
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public static bool GetUserdelete(int id)
        {
            return UserService.Userdelete(id);
        }

        /// <summary>
        /// 对用户进行封禁或解封
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public static bool UpdateBanUser(int id)
        {
            return UserService.UpdateBanUser(id);
        }
    }
}
